﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Memory
{
    public class Person
    {
        public string Name { get; set; }

        public int Age { get; set; }

        public Work Work { get; set; }

        public int[] Values { get; set; }

        public override string ToString()
        {
            return string.Format("name:{0},age:{1},work{2},values:{3}",Name,Age, Work.ToString(),string.Join(",", Values));
        }
    }

    public class Work
    {
        public string Position { get; set; }

        public string Address { get; set; }

        public override string ToString()
        {
           return string.Format($"postion:{Position},address: {Address}");
        }
    }
}
